package com.pureut.storage.service;


import com.baomidou.mybatisplus.extension.service.IService;
import com.pureut.storage.domain.AllotManagement;
import com.pureut.storage.dto.*;
import com.pureut.storage.export.AllotManagementExport;
import com.pureut.storage.vo.*;
import com.sale.common.mybatis.core.page.PageQuery;
import com.sale.common.mybatis.core.page.TableDataInfo;
import org.springframework.web.bind.annotation.GetMapping;

import java.util.List;

/**
 * 调拨管理服务层
 * @author: CM
 * @date: 2023/1/10    21:31
 */
public interface AllotManagementService extends IService<AllotManagement> {

    /**
     * 新增调拨单
     * @param allotManagementVo
     * @return
     */
    boolean addAllot(AllotManagementVo allotManagementVo) throws Exception;

    /**
     * 调拨列表
     * @param allotManagementVo
     * @return
     */
    TableDataInfo<AllotManagementDto> getList(AllotManagementVo allotManagementVo, PageQuery pageQuery);

    /**
     * 修改调拨单
     * @param allotManagementVo
     * @return
     */
    boolean updateAllot(AllotManagementVo allotManagementVo);

    /**
     * 查看调拨单
     * @param id
     * @return
     */
    AllotManagementDto view(Long id);

    /**
     * 删除单据
     * @param ids
     * @return
     */
    boolean deleteAllot(String ids);

    /**
     * 关节单据
     * @param allotManagementVo
     * @return
     */
    boolean closeAllot(AllotManagementVo allotManagementVo);

    /**
     * 调拨出库
     * @param allotDbVo
     * @return
     */
    AllotDbDto outAllot(AllotDbVo allotDbVo);

    /**
     * 调拨入库
     * @param allotDbVo
     * @return
     */
    AllotDbDto inAllot(AllotDbVo allotDbVo);

    /**
     * 拣货完成
     * @param id
     * @return
     */
    boolean finishAllot(Long id);

    /**
     * 拣货撤销
     * @param id
     * @return
     */
    boolean repealAllot(Long id);

    /**
     * 出库交接
     * @param pickingRestDbVo
     * @return
     */
    PickingRestHandoverDto overAllot(PickingRestDbVo pickingRestDbVo);

    /**
     * 拣货完成入库
     * @param id
     * @return
     */
    boolean finishAllotIn(Long id);



    /**
     * 拣货方案
     * @param id
     * @return
     */
    SchemeDto point(Long id);

    /**
     * Pda调拨列表
     * @param pageQuery
     * @param allotPdaListVo
     * @return
     */
    TableDataInfo<AndroidPdaDto> allotPdaList(PageQuery pageQuery, AllotPdaListVo allotPdaListVo);

    /**
     * Pda详情
     * @param allotPdaListVo
     * @return
     */
    AndroidPdaDto allotPdaView(AllotPdaListVo allotPdaListVo);
}
